package com.ship.dispatch.mapper.performance;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ship.common.datasource.annotation.Slave;
import com.ship.dispatch.bean.performance.PerformanceHisList;
import com.ship.dispatch.bean.performance.PerformanceList;
import com.ship.dispatch.bean.performance.PerformanceRepList;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface PerformanceListMapper extends BaseMapper<PerformanceList> {
    List<PerformanceHisList> getHisByImo(@Param("imo") String imo);

    List<PerformanceRepList> getRepByImo(String imo);

    @Select("SELECT ship_name FROM ihs_ship_base WHERE imo = #{imo}")
    @Slave
    String getNameByImo(String imo);
}
